Skip to content

fix(audit): register OTel stats handler when audit is enabled without tracing - #6280

Open
erka wants to merge 1 commit into
mainfrom
rd/v1/missing-audit-logs
Open

fix(audit): register OTel stats handler when audit is enabled without tracing#6280
erka wants to merge 1 commit into
mainfrom
rd/v1/missing-audit-logs

Conversation

@erka

@erka erka commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

The otelgrpc stats handler was only registered when tracing was enabled,
but audit logging also depends on it for creating spans that carry
audit events to the SinkSpanExporter. Without it, audit events added
via span.AddEvent were silently dropped.

closes #6279

… tracing

The otelgrpc stats handler was only registered when tracing was enabled,
but audit logging also depends on it for creating spans that carry
audit events to the SinkSpanExporter. Without it, audit events added
via span.AddEvent were silently dropped.

Signed-off-by: Roman Dmytrenko <rdmytrenko@gmail.com>
@erka
erka requested a review from a team as a code owner July 28, 2026 18:16
@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jul 28, 2026
@erka erka added the v1 Flipt v1 label Jul 28, 2026
@codecov

codecov Bot commented Jul 28, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 43.75000% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 66.92%. Comparing base (42111b0) to head (59e6176).

Files with missing lines Patch % Lines
internal/cmd/grpc.go 43.75% 8 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6280      +/-   ##
==========================================
+ Coverage   65.34%   66.92%   +1.58%     
==========================================
  Files         169      169              
  Lines       14186    14191       +5     
==========================================
+ Hits         9270     9498     +228     
+ Misses       4240     3971     -269     
- Partials      676      722      +46     
Flag Coverage Δ
unittests 66.92% <43.75%> (+1.58%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@erka erka linked an issue Jul 28, 2026 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M This PR changes 30-99 lines, ignoring generated files. v1 Flipt v1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: No audit logs in v1.61.1

1 participant